import 'package:flutter/material.dart';

class ItemWidget extends StatelessWidget {
  const ItemWidget({super.key, this.name = '', this.onTap});
  final String name;
  final VoidCallback? onTap;
  @override
  Widget build(BuildContext context) {
    return GestureDetector(
      onTap: () {
        onTap!();
      },
      child: Container(
        padding: const EdgeInsets.fromLTRB(23, 0, 14, 0),
        height: 58,
        child: Row(
          children: [
            Expanded(
              flex: 1,
              child: Text(
                name,
                style: const TextStyle(
                  color: Color(0xFFFFFFFF),
                  fontSize: 14,
                  fontWeight: FontWeight.w500,
                ),
              ),
            ),
            RotatedBox(
              quarterTurns: 2,
              child: Image.asset(
                'assets/images/left.png',
                width: 8,
              ),
            ),
          ],
        ),
      ),
    );
  }
}
